package com.jf.yytgd.entity.dto.like;

import jakarta.validation.constraints.Min;
import jakarta.validation.constraints.NotNull;
import lombok.Data;
import org.springframework.util.StringUtils;

/**
 * Created with IntelliJ IDEA
 * Description:
 * User:22954
 * Date:2025-02-09
 * Time:20:40
 */
@Data
public class LikeExistDTO {
    private Integer userId;
    private String relatedType;
    @NotNull
    @Min(1)
    private Integer relatedId;
    public boolean hasEmpty() {
        return userId == null || !StringUtils.hasText(relatedType) || relatedId == null;
    }
}
